package com.github.pig.admin.model.zhgl.house;

import java.util.Date;

import cn.afterturn.easypoi.excel.annotation.Excel;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;
import com.fasterxml.jackson.annotation.JsonFormat;

import java.io.Serializable;

/**
 * <p>
 * 房屋基本信息
 * </p>
 *
 * @author lxm
 * @since 2018-06-13
 */
@TableName("unit_house")
public class UnitHouse extends Model<UnitHouse> {

    private static final long serialVersionUID = 1L;
    public static String[] heads = {"房屋名称","户型","建筑面积","使用面积","房屋状态","所属楼层","交房时间","物业费到期日期","序号"};

    /**
     * 唯一标识
     */
    @TableId(value = "id",type = IdType.UUID)
    private String id;
    /**
     * 楼宇ID
     */
    @TableField("building_id")
    private String buildingId;
    @TableField(exist = false)
    private String buildingName;
    /**
     * 单元ID
     */
    @TableField("unit_id")
    private String unitId;
    @TableField(exist = false)
    private String unitName;
    /**
     * 房屋名称
     */
    @TableField("house_name")
    @Excel(name = "房屋名称" ,width = 20)
    private String houseName;
    /**
     * 户型
     */
    @TableField("house_type")
    @Excel(name = "户型" ,width = 20,replace = {"一居室_01","二居室_02","三居室_03","四居室_04","五居室及以上_05"})
    private String houseType;
    /**
     * 户型名称
     */
    @TableField(exist = false)
    @Excel(name = "户型名称" ,width = 20)
    private String houseTypeName;
    /**
     * 建筑面积
     */
    @TableField("build_size")
    @Excel(name = "建筑面积" ,width = 20)
    private Double buildSize;

    /**
     * 序号
     */
    @TableField("sort")
    @Excel(name = "序号" ,width = 20)
    private int sort;

    /**
     * 所属楼层
     */
    @TableField("floor")
    @Excel(name = "所属楼层" ,width = 20)
    private Integer floor;
    /**
     * 房屋状态
     */
    @Excel(name = "房屋状态" ,width = 20,replace = {"未出售_1","已出售_2","出租_3"})
    private String status;
    /**
     * 房屋状态名称
     */
    @TableField(exist = false)
    @Excel(name = "房屋状态名称" ,width = 20)
    private String houseStatusName;
    /**
     * 交房日期
     */
    @TableField("give_date")
    @Excel(name = "交房时间" ,width = 20,importFormat="yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd",timezone="GMT+8")
    private Date giveDate;


    /**
     * 文件路径
     */
    @TableField("file_path")
    private String filePath;
    /**
     * 使用面积
     */
    @TableField("use_size")
    @Excel(name = "使用面积" ,width = 20)
    private Double useSize;
    /**
     * 物业费截至日期
     */
    @TableField("proerty_endtime")
    @Excel(name = "物业费到期日期" ,width = 20,importFormat="yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd",timezone="GMT+8")
    private Date proertyEndtime;
    /**
     * 删除标识
     */
    @TableField("del_flag")
    private String delFlag;

    @TableField("community_id")
    private String communityId;

    /**
     * 创建时间
     */
    @TableField("create_time")
    private Date createTime;
    /**
     * 修改时间
     */
    @TableField("update_time")
    private Date updateTime;

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getBuildingId() {
        return buildingId;
    }

    public void setBuildingId(String buildingId) {
        this.buildingId = buildingId;
    }

    public String getUnitId() {
        return unitId;
    }

    public void setUnitId(String unitId) {
        this.unitId = unitId;
    }

    public String getHouseName() {
        return houseName;
    }

    public void setHouseName(String houseName) {
        this.houseName = houseName;
    }

    public String getHouseType() {
        return houseType;
    }

    public void setHouseType(String houseType) {
        this.houseType = houseType;
    }

    public String getHouseTypeName() {
        return houseTypeName;
    }

    public void setHouseTypeName(String houseTypeName) {
        this.houseTypeName = houseTypeName;
    }

    public String getHouseStatusName() {
        return houseStatusName;
    }

    public void setHouseStatusName(String houseStatusName) {
        this.houseStatusName = houseStatusName;
    }

    public Double getBuildSize() {
        return buildSize;
    }

    public void setBuildSize(Double buildSize) {
        this.buildSize = buildSize;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public Date getGiveDate() {
        return giveDate;
    }

    public void setGiveDate(Date giveDate) {
        this.giveDate = giveDate;
    }

    public String getFilePath() {
        return filePath;
    }

    public void setFilePath(String filePath) {
        this.filePath = filePath;
    }

    public Double getUseSize() {
        return useSize;
    }

    public void setUseSize(Double useSize) {
        this.useSize = useSize;
    }

    public Date getProertyEndtime() {
        return proertyEndtime;
    }

    public void setProertyEndtime(Date proertyEndtime) {
        this.proertyEndtime = proertyEndtime;
    }

    public String getDelFlag() {
        return delFlag;
    }

    public void setDelFlag(String delFlag) {
        this.delFlag = delFlag;
    }

    public String getBuildingName() {
        return buildingName;
    }

    public void setBuildingName(String buildingName) {
        this.buildingName = buildingName;
    }

    public String getUnitName() {
        return unitName;
    }

    public void setUnitName(String unitName) {
        this.unitName = unitName;
    }

    public int getSort() {
        return sort;
    }

    public void setSort(int sort) {
        this.sort = sort;
    }

    public String getCommunityId() {
        return communityId;
    }

    public void setCommunityId(String communityId) {
        this.communityId = communityId;
    }

    public Integer getFloor() {
        return floor;
    }

    public void setFloor(Integer floor) {
        this.floor = floor;
    }

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

    @Override
    public String toString() {
        return "UintHouse{" +
        ", id=" + id +
        ", buildingId=" + buildingId +
        ", unitId=" + unitId +
        ", houseName=" + houseName +
        ", houseType=" + houseType +
        ", buildSize=" + buildSize +
        ", status=" + status +
        ", giveDate=" + giveDate +
        ", filePath=" + filePath +
        ", useSize=" + useSize +
        ", proertyEndtime=" + proertyEndtime +
        ", delFlag=" + delFlag +
        "}";
    }
}
